<template>
    <div>
        <Navbar title="首页" :left="true" @leftEvent="handleLeft"></Navbar>
        <Navbar title="我的" :left="false"></Navbar>
    </div>
</template>

<script>
import Navbar from './Navbar.vue';

export default {
    components: {
        Navbar
    },
    setup() {
        const handleLeft = (ctx) => {
            console.log("父组件收到子组件通知：", ctx);
        }
        return {
            handleLeft
        }
    },
}
</script>